import pandas as pd
import matplotlib.pyplot as plt
data=pd.read_excel('店铺数据.xlsx')
district_counts=data['所在区'].value_counts()
plt.figure(figsize=(10,8))
plt.pie(district_counts,autopct='%1.1f%%',startangle=90,pctdistance=0.9,textprops={'fontsize': 13,'color':'w'})
plt.title('某点评网站不同区美食店铺数占比饼图',fontsize=16)
plt.rcParams['font.sans-serif']='SimHei'
plt.legend(district_counts.index)
plt.show()